<?php
//
// prints html share links (the basic ones)
//
function the_share_links(){
        
        $perma=get_permalink();
        $title=get_the_title();
        $postid = get_the_ID();
        $args = array (
                    'page_id' => $postid,
                    'heading' => "0",
                    'list_style' => "icon_text",
                    'direction' => 'row',
                    'page_title'=>$title,
                    'page_link'=>$perma,
                    'echo'=>'0',
                    'facebook_share_text' => __('Recommend','share-and-follow'),
                    'stumble_share_text'=> __('Stumble uppon','share-and-follow'),
                    'twitter_share_text'=>__('Tweet','share-and-follow'),
                    'delicious_share_text'=>__('Bookmark','share-and-follow'),
                    'digg_share_text'=>__('Digg','share-and-follow'),
                    'reddit_share_text'=>__('Share','share-and-follow'),
                    'hyves_share_text'=>__('Tip','share-and-follow'),
                    'orkut_share_text'=>__('Share','share-and-follow'),
                    'myspace_share_text'=>__('Share','share-and-follow'),
        );
        social_links($args);
}
//
// Shows the links that are clicked in the admin screen.
//
function my_share_links(){
        $optionname = "ShareAndFollowAdminOptions";
        $devOptions = get_option($optionname);
        $perma=get_permalink();
        $title=get_the_title();
        $postid = get_the_ID();
        $args = array (
                    'page_id' => $postid,
                    'heading' => "0",
                    'direction' => 'row',
                    'page_title'=>$title,
                    'page_link'=>$perma,
                    'echo'=>'0',

        );
        $adminSettings = array('size','spacing','share','list_style','email_body_text','share_text','css_images');
        foreach ($adminSettings as $item){
            $args[$item] = $devOptions[$item];
        }
        global $shareAndFollowShareIcons;
        $shareIcons = $shareAndFollowShareIcons;
        $shareIcons[]='post_rss';
        foreach ($shareIcons as $item){
            $args[$item] = $devOptions[$item];
            $args[$item.'_share_text'] = $devOptions[$item.'_share_text'];
            $args[$item.'_popup_text'] = $devOptions[$item.'_popup_text'];
        }
        social_links($args);
}

function my_wp_ecommerce_share_links(){
        $optionname = "ShareAndFollowAdminOptions";
        $devOptions = get_option($optionname);
        $perma=wpsc_the_product_permalink();
        $title=wpsc_the_product_title();
        // $postid = get_the_ID();
        $args = array (
                    'heading' => "0",
                    'direction' => 'row',
                    'page_title'=>$title,
                    'page_link'=>$perma,
                    'echo'=>'0',

        );
        $adminSettings = array('size','spacing','share','list_style','email_body_text','share_text','css_images');
        foreach ($adminSettings as $item){
            $args[$item] = $devOptions[$item];
        }
        global $shareAndFollowShareIcons;
        $shareIcons = $shareAndFollowShareIcons;
        $shareIcons[]='post_rss';
        foreach ($shareIcons as $item){
            $args[$item] = $devOptions[$item];
            $args[$item.'_share_text'] = $devOptions[$item.'_share_text'];
            $args[$item.'_popup_text'] = $devOptions[$item.'_popup_text'];
        }
        social_links($args);
}


function my_follow_links(){
        $optionname = "ShareAndFollowAdminOptions";
        $devOptions = get_option($optionname);

            $adminSettings = array ('list_style'=>$devOptions['follow_list_style'],                     'size'=>$devOptions['tab_size'],
                    'add_follow_text'=>$devOptions['add_follow_text'],                 'css_images'=>'yes',
                    'spacing'=>$devOptions['spacing'],                                  'add_content'=>'true',
                    'word_value'=>$devOptions['word_value'],                            'word_text'=>$devOptions['word_text'],
                    'add_follow'=>$devOptions['add_follow'],                            'add_css'=>$devOptions['add_css'],
                    'follow_rss'=>$devOptions['follow_rss'],                            'rss_text'=>$devOptions['rss_link_text'],
                    'border_color'=>$devOptions['border_color'],                        'sidebar_tab'=>'',
                    'follow_location'=>'none',                                          'list_style' => 'iconOnly',
            );

            $followIcons = array ('coconex','dailymotion','digg','facebook','flickr', 'foursquare' ,'google_buzz','gowalla', 'hyves', 'lastfm','linkedin','myspace',
                'newsletter', 'orkut','plaxo', 'soundcloud', 'stumble', 'tumblr','twitter','vimeo','vkontakte', 'xfire','xing','yahoo_buzz','yelp','youtube', 'sphinn',
                'itunes', 'picasa', 'bandcamp' , 'delicious', 'deviantart', 'moddb', 'imdb', );

        foreach ($adminSettings as $item => $settings){
            $args[$item] = $settings;
        }
        foreach ($followIcons as $item){
            $args['follow_'.$item] = $devOptions['follow_'.$item];
            $args[$item.'_link'] = $devOptions[$item.'_link'];
            $args[$item.'_link_text'] = $devOptions[$item.'_link_text'];
           // $args[$item.'_text'] = $devOptions[$item.'_text'];
        }
      follow_links($args);
}

//
// returns html share links as HTML
//

function get_the_share_links(){
       
        $perma=get_permalink();
        $title=get_the_title();
        $postid = get_the_ID();
        $args = array (
                    'page_id' => $postid,
                    'heading' => "0",
                    'list_style' => "icon_text",
                    'direction' => 'row',
                    'page_title'=>$title,
                    'page_link'=>$perma,
                    'echo'=>'1',
                    'facebook_share_text' => __('Recommend','share-and-follow'),
                    'stumble_share_text'=> __('Stumble uppon','share-and-follow'),
                    'twitter_share_text'=>__('Tweet','share-and-follow'),
                    'delicious_share_text'=>__('Bookmark','share-and-follow'),
                    'digg_share_text'=>__('Digg','share-and-follow'),
                    'reddit_share_text'=>__('Share','share-and-follow'),
                    'hyves_share_text'=>__('Tip','share-and-follow'),
                    'orkut_share_text'=>__('Share','share-and-follow'),
                    'myspace_share_text'=>__('Share','share-and-follow'),
        );
        social_links($args);
}
//
//show social links function, complete function.
//
function social_links($args){
    $defaults = array(
                    'page_id' => '0',                                           'heading' => "1",
                    'size' => "16",                                             'list_style' => "icon_text",
                    'direction' => 'down',                                      'facebook' => 'yes',
                    'twitter'=>'yes',                                           'delicious'=>'yes',
                    'digg'=>'yes',                                              'reddit'=>'yes',
                    'myspace'=>'',                                              'linkedin'=>'',
                    'hyves'=>'',                                                'tumblr'=>'',
                    'orkut'=>'',                                                'print'=>'',
                    'google_buzz'=>'',                                          'yahoo_buzz'=>'',
                    'vkontakte'=>'',
                    'bookmark'=>'',                                             'sphinn'=>'',
                    'nujij'=>'',
                    'post_rss'=>'',                                             'mixx'=>'',
                    'email'=>'',                                            'iconset'=>'default',
                    'share'=>'yes',                                             'page_excerpt'=>get_bloginfo('description'),
                    'phat'=>'',                                                 'page_title'=>'',
                    'page_link'=>'',                                            'echo'=>'0',
                    'words'=>'long',                                            'css_images'=>'no',
                    'share_text'=>__('share:','share-and-follow'),              'mixx_share_text' => __('Mixx it up','share-and-follow'),
                    'mixx_popup_text' => __('Share this BLOG : TITLE on Mixx','share-and-follow'),
                    'vkontakte_popup_text' => __('Share this BLOG : TITLE on vkontakte','share-and-follow'),
                    'linkedin_share_text' => __('Share on Linkedin','share-and-follow'),
                    'linkedin_popup_text' => __('Share this BLOG : TITLE on Linkedin','share-and-follow'),
                    'facebook_share_text' => __('Recommend on Facebook','share-and-follow'),
                    'facebook_popup_text' => __('Recommend this BLOG : TITLE on Facebook','share-and-follow'),
                    'stumble_share_text'=> __('Share with Stumblers','share-and-follow'),
                    'stumble_popup_text'=> __('Share this BLOG : TITLE with Stumblers','share-and-follow'),
                    'twitter_share_text'=>__('Tweet this','share-and-follow'),
                    'twitter_popup_text'=>__('Tweet this BLOG : TITLE on Twitter','share-and-follow'),
                    'tumblr_share_text'=>__('Tumblr. this','share-and-follow'),
                    'tumblr_popup_text'=>__('Tumblr. this BLOG : TITLE ','share-and-follow'),
                    'delicious_share_text'=>__('Bookmark on Delicious','share-and-follow'),
                    'delicious_popup_text'=>__('Bookmark this BLOG : TITLE on Delicious','share-and-follow'),
                    'digg_share_text'=>__('Digg this','share-and-follow'),
                    'digg_popup_text'=>__('Digg this BLOG : TITLE','share-and-follow'),
                    'reddit_share_text'=>__('Share on Reddit','share-and-follow'),
                    'reddit_popup_text'=>__('Share this BLOG : TITLE on Reddit','share-and-follow'),
                    'hyves_share_text'=>__('Tip on Hyves','share-and-follow'),
                    'hyves_popup_text'=>__('Tip this BLOG : TITLE on Hyves','share-and-follow'),
                    'orkut_share_text'=>__('Share on Orkut','share-and-follow'),
                    'orkut_popup_text'=>__('Share this BLOG : TITLE on Orkut','share-and-follow'),
                    'myspace_share_text'=>__('Share via MySpace','share-and-follow'),
                    'myspace_popup_text'=>__('Share this BLOG : TITLE via MySpace','share-and-follow'),
                    'post_rss_share_text'=>__('Follow this posts comments','share-and-follow'),
                    'post_rss_popup_text'=>__('Follow this BLOG : TITLE comments','share-and-follow'),
                    'print_share_text'=>__('Print for later','share-and-follow'),
                    'print_popup_text'=>__('Print this BLOG : TITLE for reading later','share-and-follow'),
                    'email_share_text'=>__('Tell a friend','share-and-follow'),
                    'email_popup_text'=>__('Tell a friend about this BLOG : TITLE ','share-and-follow'),
                    'google_buzz_share_text'=>__('Buzz up','share-and-follow'),
                    'google_buzz_popup_text'=>__('Buzz up this BLOG : TITLE ','share-and-follow'),

                    'sphinn_share_text'=>__('Sphinn this','share-and-follow'),
                    'sphinn_popup_text'=>__('Sphinn this BLOG : TITLE ','share-and-follow'),

                    'technorati'=>'',
                    'technorati_share_text'=>__('Share on nuJIJ','share-and-follow'),
                    'technorati_popup_text'=>__('Share this BLOG : TITLE on nuJIJ','share-and-follow'),

                    'xing'=>'',
                    'xing_share_text'=>__('Share on Xing','share-and-follow'),
                    'xing_popup_text'=>__('Share this BLOG : TITLE on Xing','share-and-follow'),

                    'nujij_share_text'=>__('Share on nuJIJ','share-and-follow'),
                    'nujij_popup_text'=>__('Share this BLOG : TITLE on nuJIJ','share-and-follow'),

                    'bookmark_share_text'=>__('bookmark','share-and-follow'),
                    'bookmark_popup_text'=>__('bookmark this BLOG : TITLE ','share-and-follow'),

                    'yahoo_buzz_share_text'=>__('Buzz it','share-and-follow'),
                    'yahoo_buzz_popup_text'=>__('Buzz it this BLOG : TITLE ','share-and-follow'),
                    'email_body_text'=>__('Found this and thought of you...','share-and-follow'),
                );
    $args = wp_parse_args( $args, $defaults );
    extract( $args, EXTR_SKIP );
    if ($page_id != 0){ $page_excerpt = substr(strip_tags(get_the_content($page_id)),0,320);}
    if (empty($page_title) && empty($page_link)){
       $page_title = get_bloginfo('name');
       if(is_category() || is_archive() || is_tag() || is_month()) {
               if ( is_category() || is_archive()) {
                   $category = get_the_category();
                   $page_title = $page_title."&nbsp;|&nbsp;".$category[0]->cat_name;
                }
               if ( is_tag() ) {
                    $page_title = get_bloginfo('name')."&nbsp;|&nbsp;".single_tag_title("", true);
                }
           $page_link = ShareAndFollow::currentPageURI();
           $page_id = 0;
       }
       else if(is_front_page()) {
             $page_title = get_bloginfo('name');
             $page_link = get_option('home');
             $page_id = 0;
       }
       else{
            $page_title = get_the_title($page_id);
            $page_link = get_permalink($page_id);
            $page_excerpt = substr(get_the_content($page_id),0,120);
       }
    }
$html='';
if($heading==1){
         $html = "<h2 class=\"clean\" >". _e('Share this ');
         if ($page_id==0){$html .='blog';}
         else {$html .='page';}
         $html.= "</h2>";
}

$rssAdminOption = "permalink_structure";
$rssSettigns = get_option($rssAdminOption);
if (empty($rssSettigns)){$rss_link = $page_link."&feed=rss2";}
else {$rss_link = trailingslashit($page_link)."feed";}

if ($css_images=='yes'){$html .= "<ul class=\"socialwrap size".$size." ".$direction."\">";}
if ($css_images=='no'){$html .= "<ul class=\"socialwrap ".$direction."\">";}

if($share=='yes'){$html.="<li class=\"".$list_style." share\">".$share_text."</li>";}
if($delicious=='yes'){
            $args=array('share_url'=> 'http://delicious.com/post?url=URI&amp;title=TITLE','css_class'=>'delicious','page_id'=>$page_id,'page_link'=>$page_link, 'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'delicious', 'share_text'=>$delicious_share_text, 'popup_text'=>$delicious_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
            }
if($digg=='yes'){
            $args=array('share_url'=> 'http://digg.com/submit?url=URI&amp;title=TITLE&amp;bodytext=EXCERPT','css_class'=>'digg','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style, 'page_excerpt'=>$page_excerpt,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'digg', 'share_text'=>$digg_share_text, 'popup_text'=>$digg_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
        }
if($facebook=='yes'){
           $args=array('share_url'=> 'http://www.facebook.com/sharer.php?u=URI&amp;t=TITLE','css_class'=>'facebook','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'facebook', 'share_text'=>$facebook_share_text, 'popup_text'=>$facebook_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
            }
if($google_buzz=='yes'){
            $args=array('share_url'=> 'http://www.google.com/buzz/post?url=URI&amp;title=TITLE','css_class'=>'google_buzz','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'google_buzz', 'share_text'=>$google_buzz_share_text, 'popup_text'=>$google_buzz_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($yahoo_buzz=='yes'){
            $args=array('share_url'=> 'http://buzz.yahoo.com/buzz?targetUrl=URI','css_class'=>'yahoo_buzz','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'yahoobuzz', 'share_text'=>$yahoo_buzz_share_text, 'popup_text'=>$yahoo_buzz_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($hyves=='yes'){
             $args=array('share_url'=> 'http://hyves-share.nl/button/tip/?tipcategoryid=12&amp;rating=5&amp;title=URI&amp;body=TITLE','css_class'=>'hyves','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'hyves', 'share_text'=>$hyves_share_text, 'popup_text'=>$hyves_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($linkedin=='yes'){
             $args=array('share_url'=> 'http://www.linkedin.com/shareArticle?mini=true&amp;url=URI&amp;title=TITLE&amp;&amp;summary=EXCERPT','css_class'=>'linkedin','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'linkedin', 'share_text'=>$linkedin_share_text, 'popup_text'=>$linkedin_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($mixx=='yes'){
             $args=array('share_url'=> 'http://www.mixx.com/submit?page_url=URI','css_class'=>'mixx','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'mixx', 'share_text'=>$mixx_share_text, 'popup_text'=>$mixx_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($myspace=='yes'){
             $args=array('share_url'=> "javascript:void(window.open('http://www.myspace.com/Modules/PostTo/Pages/?u='+encodeURIComponent(document.location.toString()),'ptm','height=450,width=440').focus())",'css_class'=>'myspace','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'myspace', 'share_text'=>$myspace_share_text, 'popup_text'=>$myspace_popup_text, 'special'=>'clean');
            $html.=ShareAndFollow::makeShareLink($args);
}
if($nujij=='yes'){
             $args=array('share_url'=>'http://nujij.nl/jij.lynkx?t=TITLE&amp;u=URI', 'css_class'=>'nujij','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'nujij', 'share_text'=>$nujij_share_text, 'popup_text'=>$nujij_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($orkut=='yes'){
            $args=array('share_url'=> 'http://promote.orkut.com/preview?nt=orkut.com&amp;du=URI&amp;tt=TITLE','css_class'=>'orkut','page_id'=>$page_id,'page_link'=>$page_link, 'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'orkut', 'share_text'=>$orkut_share_text, 'popup_text'=>$orkut_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($reddit=='yes'){
            $args=array('share_url'=> 'http://www.reddit.com/submit?url=URI&amp;title=TITLE','css_class'=>'reddit','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'reddit', 'share_text'=>$reddit_share_text, 'popup_text'=>$reddit_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($stumble=='yes'){
                $args=array('share_url'=> 'http://www.stumbleupon.com/submit?url=URI&amp;title=TITLE','css_class'=>'stumble','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'stumbleupon', 'share_text'=>$stumble_share_text, 'popup_text'=>$stumble_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}

if($sphinn=='yes'){
            $args=array('share_url'=> 'http://www.sphinn.com/share?v=3&amp;u=URI&amp;t=TITLE','css_class'=>'sphinn','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'sphinn', 'share_text'=>$sphinn_share_text, 'popup_text'=>$sphinn_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}

if($technorati=='yes'){
            $args=array('share_url'=> 'http://technorati.com/faves?add=URI','css_class'=>'technorati','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'technorati', 'share_text'=>$technorati_share_text, 'popup_text'=>$technorati_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($tumblr=='yes'){
            $args=array('share_url'=> 'http://www.tumblr.com/share?v=3&amp;u=URI&amp;t=TITLE','css_class'=>'tumblr','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'tumblr', 'share_text'=>$tumblr_share_text, 'popup_text'=>$tumblr_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($twitter=='yes'){
            $args=array('share_url'=> 'http://twitter.com/home/?status=TITLEURI','css_class'=>'twitter','page_id'=>$page_id,'page_link'=>$page_link, 'special'=>"twitter",  'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'twitter', 'share_text'=>$twitter_share_text, 'popup_text'=>$twitter_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($vkontakte=='yes'){
            $args=array('share_url'=> 'http://vkontakte.ru/share.php?url=URI&amp;title=TITLE&amp;description=EXCERPT','css_class'=>'vkontakte','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'vkontakte', 'share_text'=>$vkontakte_share_text, 'popup_text'=>$vkontakte_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($xing=='yes'){
            $args=array('share_url'=> 'http://www.xing.com/app/user?op=share;url=URI','css_class'=>'xing','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'xing', 'share_text'=>$xing_share_text, 'popup_text'=>$xing_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($post_rss=='yes'){
            $args=array('share_url'=> $rss_link,'css_class'=>'rss','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,'target'=>"",
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'rss', 'share_text'=>$post_rss_share_text, 'popup_text'=>$post_rss_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($email=='yes'){
            $args=array('share_url'=> $rss_link,'css_class'=>'email','page_id'=>$page_id,'page_link'=>$page_link, 'target'=>"", 'special'=>"email", 'email_body'=>$email_body_text, 'list_style'=>$list_style,
                        'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'email', 'share_text'=>$email_share_text, 'popup_text'=>$email_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
            }
if($print=='yes'){
            $args=array('share_url'=> 'javascript:window.print();','css_class'=>'print','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style, 'target'=>"",
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'print', 'share_text'=>$print_share_text, 'popup_text'=>$print_popup_text);
            $html.=ShareAndFollow::makeShareLink($args);
}
if($bookmark=='yes'){
            $args=array('share_url'=> "javascript:window.bookMark('$page_link', '$page_title', BrowserDetect.browser);",'css_class'=>'bookmark','page_id'=>$page_id,'page_link'=>$page_link,  'list_style'=>$list_style,'target'=>"", 'special'=>'clean',
                    'page_title'=>$page_title, 'css_images'=>$css_images, 'size'=>$size, 'image_name'=>'bookmark', 'share_text'=>$bookmark_share_text, 'popup_text'=>$bookmark_popup_text, 'rel'=>'sidebar');
            $html.=ShareAndFollow::makeShareLink($args);
}
$html .= "</ul>";

if ($direction=='row'){$html .= "<div class=\"clean\"></div> ";}
if ($echo=='0'){
    echo $html;
}
else {return $html;}
}
//
// the follow links setup
//

function follow_links($args){
    $defaults = array(
                    'size' => "16",
                    'list_style' => 'text_replacement',
                    'icon_set'=>'default',
                    'direction' => 'down',
                    'iconset'=>'default',
                    'word_value'=>'follow',
                    'word_text'=>__('follow:','share-and-follow'),
                    'phat'=>'',
                    'page_title'=>'',
                    'page_link'=>'',
                    'echo'=>'0',
                    'words'=>'long',
                    'sidebar_tab'=>'tab',
                    'add_follow_text'=>'true',
                    'css_images'=>'no',
                    'follow_location'=>'right',
                    'facebook_text'=>__('Become a Fan','share-and-follow'),

                    'coconex_text'=>__('Connect with us','share-and-follow'),
                    'plaxo_text'=>__('Join my address book','share-and-follow'),
                    'vkontakte_text'=>__('Become Friends','share-and-follow'),
                    'gowalla_text'=>__('Follow my actions','share-and-follow'),
                    'xing_text'=>__('Connect with us','share-and-follow'),

                    'digg_text'=>__('Digg my stuff','share-and-follow'),

                    'soundcloud_text'=>__('Listen to my music','share-and-follow'),
                    'vimeo_text'=>__('Watch my video','share-and-follow'),
                    'dailymotion_text'=>__('Tune to my channel','share-and-follow'),
                    'foursquare_text'=>__('Follow me on Foursquare','share-and-follow'),
                    'lastfm_text'=>__('Check my tunes','share-and-follow'),
                    'stumble_text'=>__('Follow my Stumbles','share-and-follow'),
                    'twitter_text'=>__('Tweet with me','share-and-follow'),
                    'tumblr_text'=>__('Tumblr.','share-and-follow'),
                    'youtube_text'=>__('Subscribe to my Channel','share-and-follow'),
                    'hyves_text'=>__('Become Hyves friends','share-and-follow'),
                    'orkut_text'=>__('Become Orkut friends','share-and-follow'),
                    'myspace_text'=>__('Become my MySpace follower','share-and-follow'),
                    'yelp_text'=>__('Read Reviews','share-and-follow'),
                    'newsletter_text'=>__('Join Newsletter','share-and-follow'),
                    'linkedin_text'=>__('Connect with me','share-and-follow'),
                    'flickr_text'=>__('See my photos','share-and-follow'),
                    'xfire_text'=>__('Join me on a mission','share-and-follow'),
                    'rss_text'=>__('RSS feed','share-and-follow'),
                    'google_buzz_text'=>__('Join the conversation','share-and-follow'),
                    'yahoo_buzz_text'=>__('Connect with me','share-and-follow'),
                   'sphinn_text'=>__('Read my posts','share-and-follow'),
                  'itunes_text'=>__('Listen to me','share-and-follow'),
                  'deviantart_text'=>__('See my artwork','share-and-follow'),
                  'moddb_text'=>__('Gamer? my mods','share-and-follow'),
                  'picasa_text'=>__('See my pictures','share-and-follow'),
                  'bandcamp_text'=>__('Listen to the band','share-and-follow'),
                  'imdb_text'=>__('Read my reviews','share-and-follow'),
                  'delicious_text'=>__('See what I share','share-and-follow'),

                );
    $args = wp_parse_args( $args, $defaults );
    extract( $args, EXTR_SKIP );
$html ='';
$rssAdminOption = "permalink_structure";
$rssSettigns = get_option($rssAdminOption);
//if (empty($rssSettigns)){$rss_link = get_option('home')."/?feed=rss2";}
//else {$rss_link = get_option('home')."/feed";}
$rss_link = get_bloginfo('rss_url');
if ($sidebar_tab=='tab'){$html .="<div id=\"follow\" class=\"".$follow_location."\">";}
    if ($css_images=='yes'){$html .= "<ul class=\"".$sidebar_tab." size".$size." ".$direction."\">";}
    if ($css_images=='no'){$html .= "<ul class=\"".$sidebar_tab." ".$direction."\">";}
    if($add_follow_text=='true') {$html .= "<li class=\"".$word_value."\"><img src=\"".WP_PLUGIN_URL."/share-and-follow/images/blank.png\"  /><span>".$word_text."</span></li>";}
        if($follow_bandcamp=='yes'&&!empty($bandcamp_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'bandcamp', 'follow_text'=>$bandcamp_text,'follow_popup_text'=>$bandcamp_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'bandcamp','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$bandcamp_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_coconex=='yes'&&!empty($coconex_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'coconex', 'follow_text'=>$coconex_text,'follow_popup_text'=>$coconex_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'coconex','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$coconex_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_email=='yes'&&!empty($email_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'email', 'follow_text'=>$email_text,'follow_popup_text'=>$email_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'email','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$email_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_dailymotion=='yes'&&!empty($dailymotion_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'dailymotion', 'follow_text'=>$dailymotion_text,'follow_popup_text'=>$dailymotion_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'dailymotion','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$dailymotion_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
         if($follow_delicious=='yes'&&!empty($delicious_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'delicious', 'follow_text'=>$delicious_text,'follow_popup_text'=>$delicious_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'delicious','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$delicious_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_deviantart=='yes'&&!empty($deviantart_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'deviantart', 'follow_text'=>$deviantart_text,'follow_popup_text'=>$deviantart_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'deviantart','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$deviantart_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_digg=='yes'&&!empty($digg_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'digg', 'follow_text'=>$digg_text,'follow_popup_text'=>$digg_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'digg','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$digg_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_facebook=='yes'&&!empty($facebook_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'facebook', 'follow_text'=>$facebook_text,'follow_popup_text'=>$facebook_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'facebook','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$facebook_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_feedburner=='yes'&&!empty($feedburner_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'feedburner', 'follow_text'=>$feedburner_text,'follow_popup_text'=>$feedburner_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'feedburner','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$feedburner_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_flickr=='yes'&&!empty($flickr_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'flickr', 'follow_text'=>$flickr_text,'follow_popup_text'=>$flickr_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'flickr','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$flickr_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_foursquare=='yes'&&!empty($foursquare_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'foursquare', 'follow_text'=>$foursquare_text,'follow_popup_text'=>$foursquare_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'foursquare','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$foursquare_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_google_buzz=='yes'&&!empty($google_buzz_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'google_buzz', 'follow_text'=>$google_buzz_text,'follow_popup_text'=>$google_buzz_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'google_buzz','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$google_buzz_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_gowalla=='yes'&&!empty($gowalla_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'gowalla', 'follow_text'=>$gowalla_text,'follow_popup_text'=>$gowalla_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'gowalla','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$gowalla_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }

        if($follow_hyves=='yes'&&!empty($hyves_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'hyves', 'follow_text'=>$hyves_text,'follow_popup_text'=>$hyves_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'hyves','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$hyves_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_imdb=='yes'&&!empty($imdb_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'imdb', 'follow_text'=>$imdb_text,'follow_popup_text'=>$imdb_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'imdb','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$imdb_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
            if($follow_itunes=='yes'&&!empty($itunes_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'itunes', 'follow_text'=>$itunes_text,'follow_popup_text'=>$itunes_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'itunes','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$itunes_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }

        if($follow_linkedin=='yes'&&!empty($linkedin_link)){
                 $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'linkedin', 'follow_text'=>$linkedin_text,'follow_popup_text'=>$linkedin_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'linkedin','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$linkedin_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_lastfm=='yes'&&!empty($lastfm_link)){
                 $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'lastfm', 'follow_text'=>$lastfm_text,'follow_popup_text'=>$lastfm_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'lastfm','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$lastfm_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_moddb=='yes'&&!empty($moddb_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'moddb', 'follow_text'=>$moddb_text,'follow_popup_text'=>$moddb_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'moddb','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$moddb_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_myspace=='yes'&&!empty($myspace_link)){
                 $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'myspace', 'follow_text'=>$myspace_text,'follow_popup_text'=>$myspace_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'myspace','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$myspace_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_newsletter=='yes'&&!empty($newsletter_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'newsletter', 'follow_text'=>$newsletter_text,'follow_popup_text'=>$newsletter_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'newsletter','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$newsletter_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_orkut=='yes'&&!empty($orkut_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'orkut', 'follow_text'=>$orkut_text,'follow_popup_text'=>$orkut_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'orkut','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$orkut_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_picasa=='yes'&&!empty($picasa_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'picasa', 'follow_text'=>$picasa_text,'follow_popup_text'=>$picasa_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'picasa','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$picasa_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_plaxo=='yes'&&!empty($plaxo_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'plaxo', 'follow_text'=>$plaxo_text,'follow_popup_text'=>$plaxo_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'plaxo','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$plaxo_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_posterous=='yes'&&!empty($posterous_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'posterous', 'follow_text'=>$posterous_text,'follow_popup_text'=>$posterous_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'posterous','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$posterous_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_rss=='yes'){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'rss', 'follow_text'=>$rss_text,'follow_popup_text'=>$rss_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'rss','rel'=>'nofollow','target'=>'_blank','follow_url'=>$rss_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_slideshare=='yes'&&!empty($slideshare_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'slideshare', 'follow_text'=>$slideshare_text,'follow_popup_text'=>$slideshare_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'slideshare','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$slideshare_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }

        if($follow_soundcloud=='yes'&&!empty($soundcloud_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'soundcloud', 'follow_text'=>$soundcloud_text,'follow_popup_text'=>$soundcloud_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'soundcloud','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$soundcloud_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_sphinn=='yes'&&!empty($sphinn_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'sphinn', 'follow_text'=>$sphinn_text,'follow_popup_text'=>$sphinn_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'sphinn','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$sphinn_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_stumble=='yes'&&!empty($stumble_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'stumble', 'follow_text'=>$stumble_text,'follow_popup_text'=>$stumble_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'stumbleupon','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$stumble_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_tumblr=='yes'&&!empty($tumblr_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'tumblr', 'follow_text'=>$tumblr_text,'follow_popup_text'=>$tumblr_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'tumblr','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$tumblr_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_twitter=='yes'&&!empty($twitter_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'twitter', 'follow_text'=>$twitter_text,'follow_popup_text'=>$twitter_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'twitter','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$twitter_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_vimeo=='yes'&&!empty($vimeo_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'vimeo', 'follow_text'=>$vimeo_text,'follow_popup_text'=>$vimeo_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'vimeo','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$vimeo_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_vkontakte=='yes'&&!empty($vkontakte_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'vkontakte', 'follow_text'=>$vkontakte_text,'follow_popup_text'=>$vkontakte_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'vkontakte','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$vkontakte_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_xfire=='yes'&&!empty($xfire_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'xfire', 'follow_text'=>$xfire_text,'follow_popup_text'=>$xfire_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'xfire','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$xfire_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_xing=='yes'&&!empty($xing_link)){
                $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'xing', 'follow_text'=>$xing_text,'follow_popup_text'=>$xing_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'xing','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$xing_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_ya=='yes'&&!empty($ya_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'ya', 'follow_text'=>$ya_text,'follow_popup_text'=>$ya_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'ya','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$ya_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }

        if($follow_yelp=='yes'&&!empty($yelp_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'yelp', 'follow_text'=>$yelp_text,'follow_popup_text'=>$yelp_text, 'size'=>$size,
                        'css_images'=>$css_images,'image_name'=>'yelp','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$yelp_link,);
                $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_youtube=='yes'&&!empty($youtube_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'youtube', 'follow_text'=>$youtube_text,'follow_popup_text'=>$youtube_text, 'size'=>$size,
                    'css_images'=>$css_images,'image_name'=>'youtube','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$youtube_link,);
            $html.=ShareAndFollow::makeFollowLink($args);
            }
        if($follow_yahoo_buzz=='yes'&&!empty($yahoo_buzz_link)){
                  $args = array('icon_set'=>$icon_set, 'list_style'=>$list_style, 'css_class'=>'yahoo_buzz', 'follow_text'=>$yahoo_buzz_text,'follow_popup_text'=>$yahoo_buzz_text, 'size'=>$size,
                    'css_images'=>$css_images,'image_name'=>'yahoobuzz','rel'=>'nofollow me','target'=>'_blank','follow_url'=>$yahoo_buzz_link,);
            $html.=ShareAndFollow::makeFollowLink($args);
            }
$html .= "</ul>";
if ($direction=='row'){$html .= "<div class=\"clean\"></div> ";}
if ($sidebar_tab=='tab'){$html .="</div>";}
if ($echo=='0'){echo $html;}
else {return $html;}
}
?>
